<include file="public@header"/>
</head>
<body>
<div class="wrap js-check-wrap">

    <form class="well form-inline margin-top-20" method="post" action="{:url('admin_store/index')}">
        店铺名称:
        <input type="text" class="form-control" name="keyword" style="width: 200px;"
               value="{$keyword|default=''}" placeholder="请输入关键字">
        <button class="btn btn-primary">搜索</button>
    </form>
    <form class="js-ajax-form" method="post">

        <table class="table table-hover table-bordered table-list">
            <thead>
            <tr>

                <th width="100">ID</th>
                <th>店铺名称</th>
                <th>位置</th>
                <th width="80">掌柜的</th>
                <th width="160">开店时间</th>
                <th width="80">状态</th>
                <th width="120">操作</th>
            </tr>
            </thead>
            <php>$status=array("1"=>'已发布',"0"=>'未发布');</php>
            <foreach name="store_list" item="vo">
                <php>$vo['more']=json_decode($vo['more'],true);</php>
                <tr>

                    <td>{$vo.id}</td>
                    <td>
                        <notempty name="vo.more.thumbnail">
                            <a href="javascript:parent.imagePreviewDialog('{:cmf_get_image_preview_url($vo.more.thumbnail)}');">
                                <i class="fa fa-photo fa-fw" style="display: block;float: left; height: 20px; line-height: 20px;"></i>
                            </a>
                        </notempty>&nbsp;
                        {$vo.store_name}</td>
                    <td>{:get_city_info($vo['province_id'],$vo['city_id'],$vo['district_id'])}</td>
                    <td>{$vo.user_login}</td>
                    <td>{:date('Y-m-d H:i',$vo['store_time'])}</td>
                    <td>
                        <notempty name="vo.status">
                            审核通过
                            <else/>
                            审核中
                        </notempty>
                    </td>
                    <td>
                        <notempty name="vo.status">
                            <a href="{:url('admin_store/index_status',array('status'=>0,'store_id'=>$vo['id']))}" class="btn btn-danger js-ajax-dialog-btn">禁用</a>
                            <else/>
                            <a href="{:url('admin_store/index_status',array('status'=>1,'store_id'=>$vo['id']))}" class="btn btn-success js-ajax-dialog-btn">审核通过</a>
                        </notempty>


                    </td>
                </tr>
            </foreach>
            <tfoot>
            <tr>

                <th width="100">ID</th>
                <th>店铺名称</th>
                <th>位置</th>
                <th width="80">掌柜的</th>
                <th width="160">开店时间</th>
                <th width="80">状态</th>
                <th width="120">操作</th>
            </tr>
            </tfoot>
        </table>

        <div class="pagination">{$page}</div>
    </form>
</div>
<script src="__STATIC__/js/admin.js"></script>
</body>
</html>